package cn.smdq.ch.upms.admin.pay.body;

import lombok.Data;

import java.math.BigDecimal;

/**
 * @author shuimodanqing
 * create at:  2019/1/29  3:07 PM
 * @description
 */
@Data
public class PayRequestBody {

    private String orderNo;

    private String payType;

    private BigDecimal amount;

    private String currency;

    private String clientIp;

    private String merchantChannel;

    private String device;

    private String subject;

    private String body;

    private String notifyUrl;

    private String param1;

    private String param2;

    private String extra;

    private String sign;

    public static class Builder {

        private PayRequestBody requestParam;

        public Builder() {
            this.requestParam = new PayRequestBody();
        }


        public Builder orderNo(String orderNo) {
            this.requestParam.orderNo = orderNo;
            return this;
        }

        public Builder payType(String payType) {
            this.requestParam.payType = payType;
            return this;
        }

        public Builder amount(BigDecimal amount) {
            this.requestParam.amount = amount;
            return this;
        }

        public Builder currency(String currency) {
            this.requestParam.currency = currency;
            return this;
        }

        public Builder clientIp(String clientIp) {
            this.requestParam.clientIp = clientIp;
            return this;
        }

        public Builder device(String device) {
            this.requestParam.device = device;
            return this;
        }

        public Builder subject(String subject) {
            this.requestParam.subject = subject;
            return this;
        }

        public Builder body(String body) {
            this.requestParam.body = body;
            return this;
        }

        public Builder merchantChannel(String merchantChannel) {
            this.requestParam.merchantChannel = merchantChannel;
            return this;
        }

        public Builder notifyUrl(String notifyUrl) {
            this.requestParam.notifyUrl = notifyUrl;
            return this;
        }

        public Builder param1(String param1) {
            this.requestParam.param1 = param1;
            return this;
        }

        public Builder param2(String param2) {
            this.requestParam.param2 = param2;
            return this;
        }

        public Builder extra(String extra) {
            this.requestParam.extra = extra;
            return this;
        }

        public Builder sign(String sign) {
            this.requestParam.sign = sign;
            return this;
        }

        public PayRequestBody build() {
            return this.requestParam;
        }
    }
}
